

package com.dog.basics.admin.controller.wishwash.api;

import com.dog.basics.common.annotation.ApiLog4j;
import com.dog.basics.common.util.R;
import com.dog.basics.bean.dto.api.wishwash.ApiDogHxOrderAddDto;
import com.dog.basics.security.annotation.Inner;
import com.dog.basics.service.wishwash.DogHxOrderService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.*;
import javax.validation.Valid;

/**
 * 订单信息
 *
 * @author cy code generator
 * @date 2021-07-09 17:40:27
 */
@RestController
@AllArgsConstructor
@RequestMapping("/api/order")
@Api(value = "订单信息管理", tags = "API:订单信息管理")
public class ApiDogHxOrderController {

    private final DogHxOrderService dogHxOrderService;


    /**
     * 订单生成
     *
     * @param obj 订单生成
     * @return R
     * @author cy code generator
     * @date 2021-07-09 17:40:27
     */
    @ApiLog4j
    @Inner
    @ApiOperation(value = "订单生成", notes = "订单生成")
    @PostMapping
    public R<Boolean> save(@Valid @RequestBody ApiDogHxOrderAddDto obj) {
        return R.ok(dogHxOrderService.saveApiObj(obj));
    }

}
